<template>
  <div id="centerTop2">
    <div class="mode1 flex_center">
      <div class="item">
        <div class="card transition">
          {{ apiData.curNum || 0 }}
        </div>
        <div class="title">
          警情总量
        </div>
      </div>
      <div class="item">
        <div class="card transition">
          {{ apiData.tongQiNum || 0 }}
        </div>
        <div class="title">
          同期警情量
        </div>
      </div>
      <div class="item">
        <div class="card transition">

          <span style="font-size: 16px" v-if="apiData.curNum !== apiData.tongQiNum">
            {{ apiData.curNum > apiData.tongQiNum ? '⬆' : '⬇' }}
          </span>
          <template v-if="apiData.curNum !== apiData.tongQiNum">
            {{ apiData.tongBiBianHuaLiang  || 0 }}
            <span style="font-size: 16px"> %</span>
          </template>
          <template v-else>
            持平
          </template>
        </div>
        <div class="title">
          同比变化量
        </div>
      </div>
    </div>
  </div>
</template>

<script>
export default {
  name: '',
  props: {
    mode: {
      default: 1
    },
    apiData: {}
  },
  created() {
  },
  mounted() {
  },
  data() {
    return {}
  },
  methods: {}
}
</script>
<style scoped lang="scss">
#centerTop2 {
  margin-top: 26px;

  .mode1 {
    .item {
      margin-right: 72px;

      &:nth-last-child(1) {
        margin-right: 0;
      }

      .card {
        min-width: 120px;
        padding: 14px 14px;
        background-image: url("@/assets/img/top2_card_bg.png");
        background-position: center center;
        background-repeat: no-repeat;
        background-size: 100%;
        font-weight: 600;
        font-size: 32px;
        color: #D9EAFF;
        line-height: 32px;
        text-align: center;

      }

      .title {
        text-align: center;
        margin-top: 16px;
      }
    }
  }
}
</style>
